package chapter04.Demo1;
class Animal5{
    //定义动物的叫法
    void shout(){
        System.out.println("动物发出叫声");
    }
}
//定义Dog类继承Animal类
class Dog5 extends Animal{
    void shout(){
        System.out.println("汪汪汪......");
    }
}
//定义测试类
public class Example04 {
    public static void main(String[] args) {
        Dog dog = new Dog();
        dog.getColor();
    }
}
